package payrechargelogic

import (
	"context"
	"gitee.com/liuxuezhan/ar-platform/assets-rpc/internal/dao/model/recharge"

	"gitee.com/liuxuezhan/ar-platform/assets-rpc/internal/svc"
	"gitee.com/liuxuezhan/ar-platform/assets-rpc/rpc"

	"github.com/zeromicro/go-zero/core/logx"
)

type RechargeOrderListPageLogic struct {
	ctx    context.Context
	svcCtx *svc.ServiceContext
	logx.Logger
}

func NewRechargeOrderListPageLogic(ctx context.Context, svcCtx *svc.ServiceContext) *RechargeOrderListPageLogic {
	return &RechargeOrderListPageLogic{
		ctx:    ctx,
		svcCtx: svcCtx,
		Logger: logx.WithContext(ctx),
	}
}

// 充值记录查询
func (l *RechargeOrderListPageLogic) RechargeOrderListPage(in *rpc.RechargeOrderListPageRequest) (*rpc.RechargeOrderListPageResponse, error) {
	return recharge.NewRechargeOrderModel(l.ctx, l.svcCtx.Db).GetRechargeOrderListPage(in)
}
